<template>
  <el-dialog
    title="成分详情"
    :visible="ingredientDialog"
    width="65%"
    @close="$emit('close')"
  >
    <!-- 物品列表 -->
    <el-table :data="info" style="width: 100%">
      <el-table-column type="index" label="序号" width="50" align="center" />
      <el-table-column prop="ingredientName" label="成分名称" align="center" />
      <el-table-column prop="value" label="标准值" align="center" />
      <el-table-column prop="uncertainty" label="不确定度" align="center" />
      <el-table-column prop="ingredientUnit" label="单位" align="center" />
    </el-table>

    <span slot="footer" class="dialog-footer">
      <el-button type="primary" @click="$emit('close')">确 定</el-button>
    </span>
  </el-dialog>
</template>

<script>
export default {
  props: {
    ingredientDialog: {
      type: Boolean,
      default: false
    },
    info: {
      type: Array,
      default: () => []
    }
  },
  data() {
    return {}
  },
  computed: {

  },

  created() {},

  methods: {}
}
</script>

<style scoped lang="scss">
.el-table {
  margin-top: 30px;
}
.el-table ::v-deep th.el-table__cell {
  background-color: #5a9cf8;
  color: #fff;
}

.el-step.is-simple ::v-deep .el-step__title {
  font-size: 14px;
}
.reason {
  font-size: 14px;
  padding: 5px;
  margin-top: 10px;
  background-color: #f5f7fa;
  min-height: 50px;
  >div {
    display: flex;
    padding: 10px;
    span {
      width: 80px;
      text-align: right;
      margin-right: 15px;
    }
  }
}
</style>
